﻿<%@ Page Title="صفحة المدير الرئيسية" Language="C#" MasterPageFile="~/MainMaster.master" AutoEventWireup="true" CodeFile="ManagerDefault.aspx.cs" Inherits="ManagerDefault" meta:resourcekey="PageResource1" %>
<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="ajx" %>
<%@ Register Src="~/Sendmail.ascx" TagName="Sendmail" TagPrefix="SM" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" Runat="Server">
    <link href="jqModal.css" rel="stylesheet" type="text/css" />
  <%--  <link href="ajaxkit.css" rel="stylesheet" type="text/css" />--%>
 <script src="jqModal.js" type="text/javascript"></script>
    <script type="text/javascript">
 
    function there() {

        $("#dialog").jqm({ modal: true }).jqmShow();


    }
    
      </script>
      <style type="text/css">
   .newzr3{
	background:  url('images/Untitled-2_03.png') right ;

	height:34px;
	 background-repeat:no-repeat;
	 float:left;
	 margin-top:-5px;
	 text-align: center;
	 padding-right:15px;
	 cursor:pointer;
	 font-family:Tahoma;
	 font-size:14px;
	 color:#003353;
	 text-decoration:none;
	 
}
.newzr3:hover{
	color: #00b4ff;
	background-image:url('images/Untitled-2ho_03.png');
	background-repeat:no-repeat;

}
        	
        	.zr3 {
	background-image:url('images/button2.png');
	display:block;
	float:right;
	 padding: 0px 10px 0px 10px;
	height:21px;
	text-align:center;
	color:#fff;
	text-shadow:1px 1px 0px #003a5e;
	margin-right:2px;
	line-height:19px;
	font-weight:bold;
	text-decoration:none;
	font-family:Tahoma;
	font-size:12px;


}
.zr3:hover ,.zr3:active {
	background-image:url('images/button2.png');
	text-shadow:1px 1px 0px #003a5e;
	background-position:0px -21px;
	
}
  .stylelabel3
       {
       	color:#064c66;
	 font-weight:bold;
	 direction:rtl;
	 text-align:right;
       	}
             .tab3{
	width:815px;
 direction:rtl;
 border:1px #ccc solid;
 border-radius:5px;
 }

tr .tabbone3{
	 background-color:#028ac5;
	 font-size:11px;
	 line-height:20px;
	 font-family:Tahoma;
  	 color:#fff;
  	 text-align:center;
	
}
 .req3
       {
           color:Red;
       } 
.adel3{
	background-color:#ededed;
	font-size:10px;
	color:#084f86;
	font-family:Tahoma;
	height:30px;
	text-align:  center;
}
.he3{
	background-color:#fff;
	padding:5px;
	font-family:Tahoma;
	font-size:14px;
	font-weight:bold;
}
       
        .jqmWindow {
    display: none;
    
    position: fixed;
    top: 17%;
    left: 40%;
    
    margin-left: -200px;
    width: 800px;
    
    background-color: #fff;
    color: #333;
    border: 1px solid black;
}
/*Hover Menu*/
.popupMenu {
	position:absolute;
	visibility:hidden;
	background-color:#F5F7F8;
	opacity:.9;
	filter: alpha(opacity=90);
}

.popupHover {
	background-image:url(icons/header-opened.png);
	background-repeat:repeat-x;
	background-position:left top;
	background-color:#F5F7F8;
}

/*Popup Control*/
.popupControl{
	background-color:White;
	position:absolute;
	visibility:hidden;
}

.ContextMenuBreak
{
	margin:1px 1px 1px 32px;
	padding:0;
	height:1px;
	overflow:hidden;
	display:block;
	border-top: 1px solid #C5C5C5;	
}

a.ContextMenuItem
{
	margin: 1px 0 1px 0;
	display: block;
	color: #003399;
	text-decoration: none;
	cursor: pointer;	
	padding: 4px 33px 4px 33px;
	white-space: nowrap;
}

a.ContextMenuItem-Selected
{
	font-weight: bold;
}

a.ContextMenuItem:hover
{
	background-color: #FFE6A0;
	color: #003399;
	border: 1px solid #D2B47A;
	padding: 3px 32px 3px 32px;
}

        .jqmWindow {
    display: none;
    position: fixed;
    top: 17%;
    left: 40%;
    
    margin-left: -300px;
    width: 800px;
    
    background-color: #fff;
    color: #333;
    border: 1px solid black;
    padding: 12px;
}

.jqmOverlay { background-color: #000; }

/* Fixed posistioning emulation for IE6
     Star selector used to hide definition from browsers other than IE6
     For valid CSS, use a conditional include instead */
* html .jqmWindow 
{
     position: absolute;
     top: expression((document.documentElement.scrollTop || document.body.scrollTop) + Math.round(17 * (document.documentElement.offsetHeight || document.body.clientHeight) / 100) + 'px');
}
            </style>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">
    <br />
    <table width="100%">
    <tr>
    <td colspan="2" style="padding:5px;" align="center">
     <asp:Label ID="lastlogins" CssClass="stylelabel3" runat="server"
       Text="اخر ميعاد للزيارة" meta:resourceKey="lastlogins"></asp:Label>
    </td>
    </tr>
    <tr>
    <td align ="left" style="padding-left:10px;">
     <asp:ImageButton ID="mailsnot"  runat="server" ImageUrl="~/icons/mails.png" Height="24px"
                     
                        OnClick="mailsnot_Click" Width="28px" />

                          
        <ajx:HoverMenuExtender ID="hme2" runat="Server" HoverCssClass="popupHover" PopupControlID="PopupMenu"
        
            PopupPosition="Bottom" TargetControlID="mailsnot" PopDelay="25" />
                      
                        
       
         <asp:Label  CssClass="stylelabel3" ID="newmail" runat="server" Text="البريد الجديد" meta:resourceKey="newmail"></asp:Label>
         
           
    </td>
    <td align="right" style="padding-right:10px;">
           <asp:LinkButton ID="updatesubs" runat="server" Text="الاشتراكات الشهرية" 
              onclick="LinkButton1_Click" Font-Bold="True" meta:resourcekey="monthlysub" 
               Visible="False"></asp:LinkButton>
    
    </td>
    </tr>
    </table>
<br />
 <asp:SqlDataSource ID="SqlDataSource1" runat="server" 
        ConnectionString="<%$ ConnectionStrings:ConnectionString %>" 
        SelectCommand="upsubend" SelectCommandType="StoredProcedure">
    </asp:SqlDataSource>
  
    <asp:GridView ID="GridView1" runat="server" 
        DataSourceID="SqlDataSource1"
        AutoGenerateColumns="False" DataKeyNames="id" GridLines="None" >
        <Columns>
        
        
                <asp:TemplateField>
                            <HeaderTemplate>
                                <table  class="tab3" >
               <tr>
                            <td colspan="5" align="right">
                             <asp:ImageButton 
                              PostBackUrl="#" ID="ImageButton1" runat="server" ImageUrl="~/icons/not.png" 
           
             Height="24px" Width="28px" /> 
                            <asp:Label  CssClass="he3" ID="upsub" runat="server" Text="الاشتراكات التى قاربت على الانتهاء" meta:resourceKey="upsub"></asp:Label>
         <br />
             <br />
             </td>
                            </tr>

                                    <tr>
                                    <td class="tabbone3"  style="width:100px;">
                                        <asp:Label ID="lblpaidfees" runat="server" Text="النقود المدفوعة" meta:resourceKey="lblpaidfees" />
                                            
                                        </td>
                                        <td  class="tabbone3"  style="width:100px">
                                     <asp:Label ID="lblstartofsubs" runat="server" Text="بداية الاشتراك" meta:resourceKey="lblstartofsubs" />
                                            
                                        </td>
                                        <td class="tabbone3"   style="width:100px">
                                     <asp:Label ID="lblendofsubs" runat="server" Text="نهاية الاشتراك" meta:resourceKey="lblendofsubs" />
                                            
                                        </td>
                                        <td  class="tabbone3"  style="width:100px">
                                     <asp:Label ID="lblcompany" runat="server" Text="الجهة المشتركة" meta:resourceKey="lblcompany" />
                                            
                                        </td>

                                    <td class="tabbone3"  style="width:100px">
                                     <asp:Label  ID="lblstops" runat="server" Text="ارسال ميل" meta:resourceKey="lbledit" />
                                            
                                        </td>
                                                                       
                                    </tr>
                                </table>
                            </HeaderTemplate>
                            <ItemTemplate>
                              
                             
                                    <table  class="tab3">
                                        <tr>
                                        <td  class="adel3"  style="width:100px">
                                                <asp:Label  ID="paidfees" runat="server" Text='<%# HttpUtility.HtmlEncode(Convert.ToString(Eval("paidfees"))) %>' />
                                            </td>
                                            <td  class="adel3"  style="width:100px">
                                                <asp:Label  ID="startofsub" runat="server" Text='<%# HttpUtility.HtmlEncode(Convert.ToString(Eval("startofsub"))) %>' />
                                            </td>
                                            <td class="adel3"  style="width:100px">
                                                <asp:Label ID="endofsub" runat="server" Text='<%# Eval("endofsub") %>' />
                                            </td>
                                            <td class="adel3"   style="width:100px">
                                                <asp:Label  ID="company" runat="server" Text='<%# HttpUtility.HtmlEncode(Convert.ToString(Eval("company"))) %>' />
                                            </td>

                                        <td class="adel3"   style="width:100px">
                                             <asp:LinkButton runat="server" ID="edits" Text='ارسال ميل' meta:resourceKey="lbledit" CommandArgument='<%#Eval("CompanyID").ToString() %>' ToolTip='<%# Eval("email1") %>' OnClick="edit_Click"   />
                                            </td>
                                                                                      
                                            
                                             
                                            
                                        </tr>
                                    </table>
                                    </ItemTemplate>
                </asp:TemplateField>
      
        </Columns>
    </asp:GridView>

    <br />

<div class="jqmWindow" id="dialog">
<a href="#" class="jqmClose" style="background-image:url('images/close.png');
	 width:39px;
	 height:40px;
	  background-repeat:no-repeat;
	  display:block;
	  float:left;	"></a>

 <SM:Sendmail ID="Sendmail1" runat="server" />
</div>

<asp:Panel CssClass="popupControl" ID="PopupMenu" runat="server">
            <div>
               <%-- <asp:HyperLink ID="tomails" runat="server" NavigateUrl="~/Inbox.aspx"> </asp:HyperLink>--%>
                <asp:Repeater ID="notificationsRepeater" runat="server" >
                <SeparatorTemplate>
                </SeparatorTemplate>
                <ItemTemplate>
                    <table bgcolor="Transparent" style="border: solid 1px black;">
                        <tr>
                            
                            <td>
                                <asp:HyperLink runat="server"  Width="200px"   ID="Options" Text='<%# DataBinder.Eval(Container.DataItem, "msg")%>'
                                
                                    CssClass="ContextMenuItem" NavigateUrl='<%# this.ResolveUrl("~/" + string.Format("Inbox.aspx")) %>'/>
                            </td>
                            
                            <td>
                                <img src="icons/season2.png" alt="" width="25" height="25" />
                            </td>
                        </tr>
                    </table>
                </ItemTemplate>
            </asp:Repeater>
                
                
                </div>
        </asp:Panel>
    </asp:Content>

